/*
 * @Author: liming-pan
 * @Date: 2022-01-29 20:19:16
 * @LastEditors: liming-pan
 */
import { watch } from 'vue'
import store from '@/store'

export const watchLang = (...cbs) => {
  watch(
    () => store.getters.lang,
    () => {
      cbs.forEach((cb) => {
        cb(store.getters.lang)
      })
    },
    { deep: true }
  )
}
